(0) Obligation:

Runtime Complexity TRS:
The TRS R consists of the following rules:

compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0) → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0) → 0
main(S(x9)) → compS_f#1(iter#3(x9), 0)

Rewrite Strategy: INNERMOST

(1) RenamingProof (EQUIVALENT transformation)

Renamed function symbols to avoid clashes with predefined symbol.

(2) Obligation:

Runtime Complexity Relative TRS:
The TRS R consists of the following rules:

compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

S is empty.
Rewrite Strategy: INNERMOST

(3) TypeInferenceProof (BOTH BOUNDS(ID, ID) transformation)

Infered types.

(4) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

(5) OrderProof (LOWER BOUND(ID) transformation)

Heuristically decided to analyse the following defined symbols:
compS_f#1, iter#3

(6) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

Generator Equations:
gen_S:0'3_0(0) ⇔ 0'
gen_S:0'3_0(+(x, 1)) ⇔ S(gen_S:0'3_0(x))
gen_compS_f:id4_0(0) ⇔ id
gen_compS_f:id4_0(+(x, 1)) ⇔ compS_f(gen_compS_f:id4_0(x))

The following defined symbols remain to be analysed:
compS_f#1, iter#3

(7) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

Induction Base:
compS_f#1(gen_compS_f:id4_0(0), gen_S:0'3_0(b)) →RΩ(1)
S(gen_S:0'3_0(b))

Induction Step:
compS_f#1(gen_compS_f:id4_0(+(n6_0, 1)), gen_S:0'3_0(b)) →RΩ(1)
compS_f#1(gen_compS_f:id4_0(n6_0), S(gen_S:0'3_0(b))) →IH
gen_S:0'3_0(+(+(1, +(b, 1)), c7_0))

We have rt ∈ Ω(n1) and sz ∈ O(n). Thus, we have ircR ∈ Ω(n).

(8) Complex Obligation (BEST)

(9) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

Lemmas:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

Generator Equations:
gen_S:0'3_0(0) ⇔ 0'
gen_S:0'3_0(+(x, 1)) ⇔ S(gen_S:0'3_0(x))
gen_compS_f:id4_0(0) ⇔ id
gen_compS_f:id4_0(+(x, 1)) ⇔ compS_f(gen_compS_f:id4_0(x))

The following defined symbols remain to be analysed:
iter#3

(10) RewriteLemmaProof (LOWER BOUND(ID) transformation)

Proved the following rewrite lemma:
iter#3(gen_S:0'3_0(n590_0)) → gen_compS_f:id4_0(n590_0), rt ∈ Ω(1 + n5900)

Induction Base:
iter#3(gen_S:0'3_0(0)) →RΩ(1)
id

Induction Step:
iter#3(gen_S:0'3_0(+(n590_0, 1))) →RΩ(1)
compS_f(iter#3(gen_S:0'3_0(n590_0))) →IH
compS_f(gen_compS_f:id4_0(c591_0))

We have rt ∈ Ω(n1) and sz ∈ O(n). Thus, we have ircR ∈ Ω(n).

(11) Complex Obligation (BEST)

(12) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

Lemmas:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)
iter#3(gen_S:0'3_0(n590_0)) → gen_compS_f:id4_0(n590_0), rt ∈ Ω(1 + n5900)

Generator Equations:
gen_S:0'3_0(0) ⇔ 0'
gen_S:0'3_0(+(x, 1)) ⇔ S(gen_S:0'3_0(x))
gen_compS_f:id4_0(0) ⇔ id
gen_compS_f:id4_0(+(x, 1)) ⇔ compS_f(gen_compS_f:id4_0(x))

No more defined symbols left to analyse.

(13) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

(14) BOUNDS(n^1, INF)

(15) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

Lemmas:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)
iter#3(gen_S:0'3_0(n590_0)) → gen_compS_f:id4_0(n590_0), rt ∈ Ω(1 + n5900)

Generator Equations:
gen_S:0'3_0(0) ⇔ 0'
gen_S:0'3_0(+(x, 1)) ⇔ S(gen_S:0'3_0(x))
gen_compS_f:id4_0(0) ⇔ id
gen_compS_f:id4_0(+(x, 1)) ⇔ compS_f(gen_compS_f:id4_0(x))

No more defined symbols left to analyse.

(16) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

(17) BOUNDS(n^1, INF)

(18) Obligation:

Innermost TRS:
Rules:
compS_f#1(compS_f(x2), x1) → compS_f#1(x2, S(x1))
compS_f#1(id, x3) → S(x3)
iter#3(0') → id
iter#3(S(x6)) → compS_f(iter#3(x6))
main(0') → 0'
main(S(x9)) → compS_f#1(iter#3(x9), 0')

Types:
compS_f#1 :: compS_f:id → S:0' → S:0'
compS_f :: compS_f:id → compS_f:id
S :: S:0' → S:0'
id :: compS_f:id
iter#3 :: S:0' → compS_f:id
0' :: S:0'
main :: S:0' → S:0'
hole_S:0'1_0 :: S:0'
hole_compS_f:id2_0 :: compS_f:id
gen_S:0'3_0 :: Nat → S:0'
gen_compS_f:id4_0 :: Nat → compS_f:id

Lemmas:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

Generator Equations:
gen_S:0'3_0(0) ⇔ 0'
gen_S:0'3_0(+(x, 1)) ⇔ S(gen_S:0'3_0(x))
gen_compS_f:id4_0(0) ⇔ id
gen_compS_f:id4_0(+(x, 1)) ⇔ compS_f(gen_compS_f:id4_0(x))

No more defined symbols left to analyse.

(19) LowerBoundsProof (EQUIVALENT transformation)

The lowerbound Ω(n1) was proven with the following lemma:
compS_f#1(gen_compS_f:id4_0(n6_0), gen_S:0'3_0(b)) → gen_S:0'3_0(+(+(1, n6_0), b)), rt ∈ Ω(1 + n60)

(20) BOUNDS(n^1, INF)